<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">


<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:c="http://java.sun.com/jsp/jstl/core"
      xmlns:f="http://xmlns.jcp.org/jsf/core"
      xmlns:h="http://xmlns.jcp.org/jsf/html"
      xmlns:ui="http://xmlns.jcp.org/jsf/facelets">
    <h:body>
	<ui:composition template="/WEB-INF/jsf2/templates/templateBasic.xhtml">
	    <ui:define name="top">
		<ui:include src="/WEB-INF/jsf2/templates/templateNavigation.xhtml"/>
	    </ui:define>
	    <ui:define name="bottom">
		<ui:include src="/WEB-INF/jsf2/templates/templateBottom.xhtml"/>
	    </ui:define>

	    <ui:define name="content">
		<f:loadBundle basename="com.gq2.multilang.championship" var="txt_cha"/>
		<f:loadBundle basename="com.gq2.multilang.granq" var="txt_com"/>

		<h3 align="left">
		    <h:outputFormat value="#{txt_cha.listChampionships}"/>
		</h3>
		<h:form id="championshipList_form">
		    <h:inputHidden id="runAction" value="#{championship.runAction}" />
		    <h:inputHidden id="keyId" value="#{championship.chaId}"/>

		    <c:set var="championshipList" value="#{championship.championshipList}" scope="session"/>

		    <table>
			<tr>
			    <td>
				<h:dataTable cellpadding="0px" cellspacing="0px"
					     columnClasses="col-center,col-left,col-left,col-center"
					     headerClass="list-header" id="dataTable1" rowClasses="list-row-even,list-row-odd" 
					     value="#{championship.championshipList}"  var="currentRow" width="950pt">
				    <h:column id="column2"> 
					<h:outputText id="outputText3" value="#{currentRow['chaId']}"/>
					<f:facet name="header">
					    <h:outputText id="outputText4" value="#{txt_cha.Id}"/>
					</f:facet>
				    </h:column>
				    <h:column id="column3">
					<h:outputText id="outputText5" value="#{currentRow['chaCode']}"/>
					<f:facet name="header">
					    <h:outputText id="outputText6" value="#{txt_com.Code}"/>
					</f:facet>
				    </h:column>
				    <h:column id="column4">
					<h:outputText id="outputText7" value="#{currentRow['chaDescription']}"/>
					<f:facet name="header">
					    <h:outputText id="outputText8" value="#{txt_com.Description}  "/>
					</f:facet>
				    </h:column>
				    <h:column id="column11" headerClass="col-center">
					<f:facet name="header">
					    <h:outputText id="outputText21" value="#{txt_com.Action}"/>
					</f:facet>
					<h:commandButton action="#{championship.edit(currentRow)}" id="button20" styleClass="button-short" 
							 value="#{txt_com.Edit}">
					</h:commandButton>
					<h:commandButton action="#{championship.delete(currentRow)}" id="button21" styleClass="button-short" 
							 value="#{txt_com.Delete}">
					</h:commandButton>
				    </h:column>
				</h:dataTable>
				<c:if test="#{championship.championshipList.size() == 0}">
				    <h3 align="left">#{txt_cha.NoListCtos}</h3>
				</c:if>
			    </td>
			    <td>
				<table class="commandBoxInList">
				    <tr>
					<td>
					    <h:commandButton action="#{championship.create}" value="#{txt_com.New}"/>
					</td>
				    </tr>
				    <tr>
					<td>
					    <h:commandButton action="#{championship.search}" value="#{txt_com.Search}"/>
					</td>
				    </tr>
				</table>
			    </td>
			</tr>
		    </table>
		</h:form>
	    </ui:define>
	</ui:composition>
    </h:body>
</html>

